PROJECT(LANGDECT)
INCLUDE_DIRECTORIES(.)
INCLUDE_DIRECTORIES(../lib/)
SET(SRC_LIST Main.cpp Text.h Text.cpp UtfText.h UtfText.cpp GbkText.h GbkText.cpp TextFactory.h TextFactory.cpp UCharDet.h CodeDetector.h CodeDetector.cpp LM.h LM.cpp WordLM.h WordLM.cpp LangDetector.h LangDetector.cpp Config.h Config.cpp ConfigItem.h ConfigItem.cpp)
SET(EXECUTABLE_OUTPUT_PATH ${LANGDECT_BINARY_DIR}/bin)
SET(LIB_PATH ${LANGDECT_SOURCE_DIR}/../lib/)
#SET(LIB_PATH /home/liuyi/workspace/job/languagedetection/CodeDect3.0/src/lib/)

MESSAGE(STATUS "This is BINARY dir " ${LANGDECT_BINARY_DIR})
MESSAGE(STATUS "This is SOURCE dir " ${LANGDECT_SOURCE_DIR})

#AUX_SOURCE_DIRECTORY(. SRC_LIST)
ADD_EXECUTABLE(CodeDect ${SRC_LIST})
#ADD_LIBRARY(CodeDect SHARED ${SRC_LIST})

#ADD_LIBRARY(lib_tibet_code ${SRC_LIST})
TARGET_LINK_LIBRARIES(CodeDect ${LIB_PATH}libuchardet.a)
TARGET_LINK_LIBRARIES(CodeDect ${LIB_PATH}libsrilm.a)
#TARGET_LINK_LIBRARIES(CodeDect ${LIB_PATH}libdstruct.a)
TARGET_LINK_LIBRARIES(CodeDect ${LIB_PATH}libz.a)
